<template>
  <div>
    <el-form ref="form" :model="form" label-width="120px">
      <el-form-item label="土题类型">
        <el-select v-model="form.type" placeholder="请选择土题类型">
          <el-option label="一、二类土（普通土）" value="1"></el-option>
          <el-option label="三类土（坚土）" value="3"></el-option>
          <el-option label="四类土（砂砾坚土）" value="4"></el-option>
        </el-select>
      </el-form-item>
      <el-form-item label="基坑类型">
        <el-select v-model="form.pit" placeholder="请选择基坑类型">
          <el-option label="基坑" value="jikeng"></el-option>
          <el-option label="沟槽" value="goucao"></el-option>
        </el-select>
      </el-form-item>
      <el-form-item label="作业方式">
        <el-select v-model="form.Operation" placeholder="请选择作业方式">
          <el-option label="人工挖土" value="rengong"></el-option>
          <el-option label="坑内作业(机械挖土) " value="nei"></el-option>
          <el-option label="坑上作业(机械挖土)" value="shang"></el-option>
        </el-select>
      </el-form-item>
      <el-form-item label="开挖坡度">
        <el-input style="width: 200px" v-model="form.slope"></el-input>
      </el-form-item>
      <el-form-item label="开挖起点深度">
        <el-input :disabled="true" style="width: 200px" v-model="form.size"></el-input>
      </el-form-item>
      <el-form-item label="开挖深度">
        <el-input style="width: 200px" v-model="form.high"></el-input>
      </el-form-item>
      <el-form-item label="基槽计算长度(m)">
        <el-input style="width: 200px" v-model="form.length"></el-input>
      </el-form-item>
      <el-form-item label="槽底开挖宽度(m)">
        <el-input style="width: 200px" v-model="form.weight"></el-input>
      </el-form-item>
      <el-form-item>
        <el-button type="primary" @click="onSubmit">立即创建</el-button>
        <el-button>取消</el-button>
      </el-form-item>
    </el-form>

  </div>
</template>

<script>
export default {
  name: 'tufangliang',
  data(){
    return{
      form:{
        type:'',
        Operation:'',
        pit:'',
        depth:'',
        height:'',
        length:'',
        weight:'',
        slope:'',
        size:''
      }
    }
  },
  methods:{
    onSubmit(){
      if (this.form.type=="1"&&this.form.Operation=="rengong"){
        this.form.slope=0.5
        this.form.size=1.2
      }
      else if (this.form.type=="1"&&this.form.Operation=="nei"){
        this.form.slope=0.33
        this.form.size=1.2
      }
      else if (this.form.type=="1"&&this.form.Operation=="shang"){
        this.form.slope=0.75
        this.form.size=1.2
      }
      else if (this.form.type=="3"&&this.form.Operation=="rengong"){
        this.form.slope=0.33
        this.form.size=1.5
      }
      else if (this.form.type=="3"&&this.form.Operation=="nei"){
        this.form.slope=0.25
        this.form.size=1.5
      }
      else if (this.form.type=="3"&&this.form.Operation=="shang"){
        this.form.slope=0.67
        this.form.size=1.5
      }
      else if (this.form.type=="4"&&this.form.Operation=="rengong"){
        this.form.slope=0.75
        this.form.size=2.0
      }
      else if (this.form.type=="4"&&this.form.Operation=="nei"){
        this.form.slope=0.67
        this.form.size=2.0
      }
      else if (this.form.type=="4"&&this.form.Operation=="shang"){
        this.form.slope=0.33
        this.form.size=2.0
      }
      if (this.form.pit=="jikeng"){

      }else if (this.form.pit=="goucao"){

      }
    }
  }
}
</script>

<style scoped>

</style>
